<?php
/**
 * Created by LíJimpéy(：
 * User: jimpey88
 * Date: 2024/04/09
 * Email: < jimpey@qq.com >
 * Project: company-admin-tp6
 */
declare (strict_types = 1);

namespace app\backend_api\model;

/**
 * @mixin \think\Model
 */
class Articles extends BaseModel
{


    /**
     * 返回文章标签名
     * @param $value
     * @param $data
     * @return mixed
     */
    public function getSortNameAttr($value, $data)
    {
        return Sorts::where('id', $data['sort_id'])->value('name');
    }
}
